{% extends myBundleName ~ ':Layout:layout.html.twig' %}

{% block title %}{{ myTitlePrefix }} Account Create{% endblock %}

{% block content %}
<div>
<form action="{{ path('zayso_core_account_create') }}" method="post" {{ form_enctype(form) }}>
<table border="1" style="width: 800px;">
<tr><th colspan="3">Create New Zayso Account</th></tr>
<tr>
    <td style="width: 225px;">{{ form_label (form.userName) }}</td>
    <td style="width: 275px;">{{ form_widget(form.userName) }}</td>
    <td style="width: 350px;">
        For signing on to Zayso.<br />
        {{ form_errors(form.userName) }}
    </td>
</tr>
{% for passwordField in form.userPass %}
<tr>
    <td> {{ form_label (passwordField) }}</td>
    <td> {{ form_widget(passwordField) }}</td>
    <td>
        Your Zayso Password.<br />
        {{ form_errors(passwordField) }}
    </td>
</tr>
{% endfor %}
<tr><th colspan="3">Person Information</th></tr>
{% set formPerson = form.person %}
<tr>
    <td style="width: 175px;">{{ form_label (formPerson.firstName) }}</td>
    <td style="width: 275px;">{{ form_widget(formPerson.firstName) }}</td>
    <td style="width: 350px;">
        Legal name<br />
        {{ form_errors(formPerson.firstName) }}
    </td>
</tr>
<tr>
    <td> {{ form_label (formPerson.lastName) }}</td>
    <td> {{ form_widget(formPerson.lastName) }}</td>
    <td>
        Legal name<br />
        {{ form_errors(formPerson.lastName) }}
    </td>
</tr>
<tr>
    <td> {{ form_label (formPerson.nickName) }}</td>
    <td> {{ form_widget(formPerson.nickName) }}</td>
    <td>
        Will be used for assignments if given.<br />
        {{ form_errors(formPerson.nickName) }}
    </td>
</tr>
<tr>
    <td> {{ form_label (formPerson.email) }}</td>
    <td> {{ form_widget(formPerson.email) }}</td>
    <td>
        Required for password recovery.<br />
        {{ form_errors(formPerson.email) }}
    </td>
</tr>
<tr>
    <td> {{ form_label (formPerson.cellPhone) }}</td>
    <td> {{ form_widget(formPerson.cellPhone) }}</td>
    <td>
        Highly recommended.<br />
        {{ form_errors(formPerson.cellPhone) }}
    </td>
</tr>
<tr><th colspan="3">eAYSO Information</th></tr>
{% set formPersonRegAYSOV = formPerson.regAYSOV %}
<tr>
    <td>{{ form_label (formPersonRegAYSOV.regKey) }}</td>
    <td>{{ form_widget(formPersonRegAYSOV.regKey) }}</td>
    <td>
        Required.<br />
        {{ form_errors(formPersonRegAYSOV.regKey) }}
    </td>
</tr>
<tr>
    <td>{{ form_label (formPersonRegAYSOV.org) }}</td>
    <td>{{ form_widget(formPersonRegAYSOV.org) }}</td>
    <td>
        3 or 4 digit region number.<br />
        {{ form_errors(formPersonRegAYSOV.org) }}
    </td>
</tr>
<tr style="display: none;">
    <td>{{ form_label (formPersonRegAYSOV.memYear) }}</td>
    <td>{{ form_widget(formPersonRegAYSOV.memYear) }}</td>
    <td>{{ form_errors(formPersonRegAYSOV.memYear) }}</td>
</tr>
<tr style="display: none;">
    <td>{{ form_label (formPersonRegAYSOV.safeHaven) }}</td>
    <td>{{ form_widget(formPersonRegAYSOV.safeHaven) }}</td>
    <td>{{ form_errors(formPersonRegAYSOV.safeHaven) }}</td>
</tr>
<tr>
    <td>{{ form_label (formPersonRegAYSOV.refBadge) }}</td>
    <td>{{ form_widget(formPersonRegAYSOV.refBadge) }}</td>
    <td>{{ form_errors(formPersonRegAYSOV.refBadge) }}</td>
</tr>
<tr style="display: none;">
    <td>{{ form_label (formPersonRegAYSOV.refDate) }}</td>
    <td>{{ form_widget(formPersonRegAYSOV.refDate) }}</td>
    <td>{{ form_errors(formPersonRegAYSOV.refDate) }}</td>
</tr>
<tr>
    <td colspan="2"><a href="{{ path('zayso_core_welcome') }}">Back to Welcome</a></td>
    <td align="center"><input type="submit" name="accountCreateSubmit" value="Create New Zayso Account" /></td>
</tr>
<tr><td colspan="3">{{ form_errors(form) }}</td></tr>
</table>
{{ form_rest(form) }}
</form>
</div>
<h3>Instructions</h3>
<p style="max-width: 750px;">
    You can can get your 8-digit eAYSO id from eayso.org.  
</p>
{% endblock %}
